﻿using StarryEdge.Core.Enums;
using StarryEdge.Core.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace StarryEdge.Core
{
    public interface IStarryEdgeLog : IStarryEdge
    {
        IEnumerable<LogInfoModel> GetRunLog();
        IEnumerable<MesLogModel> GetMesLog();
        IEnumerable<LogInfoModel> GetOperation();
        void LogRun(string message, LogLevel logLevel = LogLevel.Info);
        /// <summary>
        /// MES日志
        /// </summary>
        /// <param name="interfaceName">接口名</param>
        /// <param name="callTime">调用时间</param>
        /// <param name="expend">耗时</param>
        /// <param name="request">请求报文</param>
        /// <param name="respond">响应报文</param>
        /// <param name="interfaceLog">日志接口名</param>
        /// <param name="barcode">条码</param>
        void LogMes(string interfaceName, DateTime callTime, long expend, string request, string respond, string interfaceLog, string barcode = default);
        void LogControls(string message, string operation, LogLevel logLevel = LogLevel.Info);
    }
}
